package com.kkb.kkbadmin.domain;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.URL;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author Taro
 * @author ${黄柯}
 * @title User
 * @projectName kkb-parent-v2
 * @description Partner对象
 * @since 2021-08-14
 */
@Data
@EqualsAndHashCode(callSuper = false)
@NoArgsConstructor
@AllArgsConstructor
@ApiModel(value = "Partner对象", description = "合作伙伴表")
@TableName("partner")
public class Partner implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "伙伴表主键id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "合作伙伴名称")
    @TableField("name")
    private String name;

    @ApiModelProperty(value = "logo图片命名")
    @TableField("image_name")
    private String imageName;

    @ApiModelProperty(value = "合作伙伴logo图片地址")
    @TableField("image_url")
    @URL
    private String imageUrl;

    @ApiModelProperty(value = "创建时间")
    @TableField("create_time")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private LocalDateTime createTime;

    @ApiModelProperty(value = "更新时间")
    @TableField("update_time")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "1:删除；0:不删除", hidden = true)
    @TableField(value = "is_deleted")
    @TableLogic(delval = "id")
    private Integer deleted;


}
